﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="cardetail.aspx.vb" Inherits="WebApplication1.cardetail" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="server">
    <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataSourceID="SqlDataSource1">
    <Columns>
        <asp:BoundField DataField="Car_Make" HeaderText="Car_Make" SortExpression="Car_Make" />
        <asp:BoundField DataField="Model" HeaderText="Model" SortExpression="Model" />
        <asp:BoundField DataField="Description" HeaderText="Description" SortExpression="Description" />
        <asp:BoundField DataField="Image" HeaderText="Image" SortExpression="Image" />
    </Columns>
</asp:GridView>
<asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:CarDataString %>" ProviderName="<%$ ConnectionStrings:CarDataString.ProviderName %>" SelectCommand="SELECT [Car Make] AS Car_Make, [Model], [Description], [Image] FROM [carclub] WHERE ([ID] = ?)">
    <SelectParameters>
        <asp:QueryStringParameter Name="ID" QueryStringField="ID" Type="Int32" />
    </SelectParameters>
    </asp:SqlDataSource>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <asp:GridView ID="GridView2" runat="server" AutoGenerateColumns="False" Width="539px">
        <Columns>
            <asp:BoundField DataField="Author" HeaderText="Author" SortExpression="Author" />
            <asp:BoundField DataField="Comment" HeaderText="Comment" SortExpression="Comment" />
            <asp:BoundField DataField="Title" HeaderText="Title" SortExpression="Title" />
        </Columns>
    </asp:GridView>
    <asp:SqlDataSource ID="SqlDataSource2" runat="server" ConnectionString="<%$ ConnectionStrings:CarDataString %>" ProviderName="<%$ ConnectionStrings:CarDataString.ProviderName %>" SelectCommand="SELECT [Author], [Comment], [Title] FROM [comments] WHERE ([car_fkId] = ?)">
        <SelectParameters>
            <asp:QueryStringParameter Name="car_fkId" QueryStringField="ID" Type="Int32" />
        </SelectParameters>



    </asp:SqlDataSource>
    <strong>
    <br />
    <br />
    Add Your Comment Here</strong><br />
    <br />
    Name
    <br />
    <asp:TextBox ID="tb_author" runat="server" Width="313px"></asp:TextBox>
    <br />
    Comment Title<br />
    <asp:TextBox ID="tb_title" runat="server" Width="312px"></asp:TextBox>
    <br />
    Your Comment<br />
    <asp:TextBox ID="tb_comment" runat="server" Height="191px" TextMode="MultiLine" Width="310px"></asp:TextBox>
    <br />
    <br />
    <asp:Button ID="btn_AddComment" runat="server" Text="Add Comment" Width="318px" />
    <br />
    <asp:CheckBoxList ID="CheckBoxList1" runat="server" DataSourceID="TagsDataSource" DataTextField="Tag" DataValueField="ID" RepeatDirection="Horizontal">
    </asp:CheckBoxList>

    Add New Tags Below<strong> (Note: Please Use Commas for each new Tag)</strong><br />
    <asp:TextBox ID="TextBox1" runat="server" Width="531px"></asp:TextBox> <br />
    <asp:SqlDataSource ID="TagsDataSource" runat="server" ConnectionString="<%$ ConnectionStrings:CarDataString %>" ProviderName="<%$ ConnectionStrings:CarDataString.ProviderName %>" SelectCommand="SELECT [ID], [Tag] FROM [tags]"></asp:SqlDataSource>
    <asp:Button ID="Button1" runat="server" Text="Tag This Car" Width="315px" />
    <br />
    <br />
</asp:Content>
